package com.rongc.client.freight.base.model;

import com.rongc.client.core.LocalData;
import com.rongc.client.core.QuickApplication;
import com.rongc.client.core.utils.FileManager;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by Bruce on 2017/7/8.
 */
public class DicsBean extends LocalData{
    List<DicBean> dics;

    public static DicsBean load(String type) {
        return FileManager.loadData(QuickApplication.getInstance(), DicsBean.class, type);
    }

    public static void clear(String type) {
        FileManager.clearData(QuickApplication.getInstance(), DicsBean.class, type);
    }

    public DicsBean() {
        this.dics = new ArrayList<>();
    }

    public List<DicBean> getDics() {
        return dics;
    }

    public void setDics(List<DicBean> dics) {
        this.dics = dics;
    }

    public static class DicBean implements Serializable{
        private static final long serialVersionUID = -1L;
        String key;
        String value;
        String attr;

        public DicBean() {
        }

        public DicBean(String key, String value) {
            this.key = key;
            this.value = value;
        }


        public String getKey() {
            return key;
        }

        public void setKey(String key) {
            this.key = key;
        }

        public String getValue() {
            return value;
        }

        public void setValue(String value) {
            this.value = value;
        }

        public String getAttr() {
            return attr;
        }

        public void setAttr(String attr) {
            this.attr = attr;
        }
    }
}

